<template>
<!--    <table border="1" align="center">
      <tr>
        <td>编号</td><td>标题</td><td>内容</td>
      </tr>
      <tr v-for="(news,index) in newsList" :key="index">
        <td>{{news.id}}</td><td>{{news.title}}</td><td>{{news.content}}</td>
      </tr>
    </table>-->
  <el-table
    :data="newsList"
    style="width: 100%">
    <el-table-column
      prop="id"
      label="编号"
      width="180">
    </el-table-column>
    <el-table-column
      prop="title"
      label="标题"
      width="180">
    </el-table-column>
    <el-table-column
      prop="content"
      label="内容">
    </el-table-column>
    <el-table-column
      prop="author"
      label="作者">
    </el-table-column>
  </el-table>
</template>

<script>
    export default {
        name: "newsList",
      data(){
          return {
            newsList:
              [
                {id:1,title:"第一条新闻",content:"aaaaaaaaaaaaaa",author:"zs"},
                {id:2,title:"第二条新闻",content:"bbbbb",author:"ls"}
              ]
          }
      }
    }
</script>

<style scoped>

</style>
